# @Author ZhangGJ
# @Date 2021/11/22 14:21

import cv2.cv2 as cv2


def gray():
    image = cv2.imread('../images/flower.jpg')
    cv2.imshow('2.1', image)

    gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)
    cv2.imshow('GRAY', gray_image)
    cv2.waitKey(5000)
    cv2.destroyAllWindows()


def hsv():
    image = cv2.imread('../images/flower.jpg')
    cv2.imshow('2.2', image)
    hsv_image = cv2.cvtColor(image, cv2.COLOR_BGR2HSV)
    cv2.imshow('HSV', hsv_image)
    cv2.waitKey(5000)
    cv2.destroyAllWindows()


if __name__ == '__main__':
    hsv()
